package com.baitai;

import com.baitai.common.core.redis.RedisCache;
import com.baitai.common.utils.spring.SpringUtils;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.context.ApplicationListener;

/**
 * 启动程序
 *
 * @author ruoyi
 */
@SpringBootApplication(exclude = {DataSourceAutoConfiguration.class})
public class BaiTaiApplication {
    public static void main(String[] args) {
        // System.setProperty("spring.devtools.restart.enabled", "false");
        SpringApplication.run(BaiTaiApplication.class, args);
        System.out.println("(♥◠‿◠)ﾉﾞ  启动成功   ლ(´ڡ`ლ)ﾞ");
//        String zcyxVersion = SpringUtils.getBean(RedisCache.class).getCacheObject("zcyx_version");
//        if (zcyxVersion == null) {
//            SpringUtils.getBean(RedisCache.class).setCacheObject("zcyx_version", "15");
//        }
    }
}
